<?php
namespace Common\Models;
use Common\BaseModel;
class Hot extends BaseModel
{
    public $res;
    public $expire;
    public function initialize()
    {
        parent::initialize();
        $this->setSource('view_home_hot');
    }


    /**
     * @param $id 极光推送的id
     * @return mixed
     */
    public function find_by_id($id)
    {
        $result = $this->findFirstById($id);
        if ($result) {
            return $result->toarray();
        } else {
            return null;
        }
    }

}
